package com.lan.mall.consumer.feign;

import com.lan.mall.common.utils.R;
import com.lan.mall.consumer.hystrix.UserServiceFallBackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "provider", contextId = "userService", fallbackFactory = UserServiceFallBackFactory.class)
public interface UserService {
    @RequestMapping("/user/getUser")
    public R getUser(@RequestParam(required = false, value = "appName") String appName);

    @RequestMapping("/user/hello")
    public R providerHello();
}
